Conventionally, multiprogramming technology of running multiple programs on a single central processing unit (CPU) has existed. Specifically, an operating system (OS) has a function of dividing the processing time of the CPU into intervals and by assigning the intervals to threads, enabling the CPU to simultaneously run multiple threads. Here, a thread is a unit into which a program is divided for execution. Further, multicore processor systems in which a computer system is equipped with multiple CPUs have been disclosed. Thus, with the multiprogramming technology, an OS can assign multiple threads to multiple CPUs.
Further, if a single CPU or multiple CPUs execute multiple threads in parallel, a synchronization process is performed to protect data shared between the threads. Synchronization is performed when, for example, multiple CPUs simultaneously access memory or when processing results are collected from CPUs after threads have been distributed and assigned to the CPUs.
Technology related to synchronization includes, for example, a disclosed technology that statistically records the time required for executing a portion of parallel processing and when the portion of parallel processing to be executed has a high potential of exceeding the statistical time, synchronization is assumed to have failed and the next process is assigned, thereby enabling the number of CPUs that are not executing a process to be reduced. Another technology related to synchronization has been disclosed in which synchronization levels according to information type and synchronization time intervals corresponding to the synchronization levels are stored, and the load for performing synchronization is reduced (for example, refer to Japanese Laid-Open Patent Publication Nos. H10-240549 and 2004-5092).
Nonetheless, with the conventional technologies above, for example, assuming that 2 threads are synchronized by the position of designated process code and one of the threads is a process that takes time, a problem arises in that the parallel processing is assumed to have failed and the threads are ended. Further, if the other thread continues to wait for the thread that takes time, the thread that continues to wait causes the response to the user to drop.